package com.lcredu.spring.component;


import com.lcredu.spring.annotation.Component;

/**
 * @author 黎长容
 * @date 2025-07-15 12:28
 */
@Component
public class SmartDog implements SmartAnimal {
    @Override
    public float getSum(float num1, float num2) {
        float res = num1 + num2;
//        int i = 10 / 0;
        System.out.println("方法内部打印result=" + res);
        return res;
    }

    @Override
    public float getSub(float num1, float num2) {
        float res = num1 - num2;
        System.out.println("方法内部打印result=" + res);
        return res;
    }
}
